package p2pcdnsim.cdn;

import p2pcdnsim.exception.CacheClassInstantiationException;
import p2pcdnsim.exception.ClientDoesNotExistException;
import p2pcdnsim.exception.NodeUnexistentException;
import p2pcdnsim.exception.SurrogateAlreadyInsertedException;
import desmoj.core.simulator.Model;

public abstract class CDNBuilder {

	protected CDN cdn;
	
	public CDN getCDN() {
		return cdn;
	}
	
	
	public abstract void createNewCDN(Model owner);
	public abstract void defineClientPlacement() throws NodeUnexistentException;
	public abstract void createAndPlaceRequestRedirector() throws NodeUnexistentException;
	public abstract void createAndPlaceOriginServer() throws NodeUnexistentException;
	public abstract void createAndPlaceSurrogates() throws CacheClassInstantiationException, SurrogateAlreadyInsertedException;
	public abstract void insertClientRequests() throws ClientDoesNotExistException;

}
